﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace MiniErp.Entity.DataStreams.DOs.AssetManagement
{
    /// <summary>
    /// 资产状态实体
    /// </summary>
    [Table("AssetState")]
    public class AssetState : BaseEntity
    {
        /// <summary>
        /// 资产状态编号
        /// </summary>
        [Key]
        [Required]
        [ConcurrencyCheck]
        [DatabaseGenerated(DatabaseGeneratedOption.Identity)]
        public int AssetStateId { get; set; }

        /// <summary>
        /// 资产状态名
        /// </summary>
        [MaxLength(20,ErrorMessage ="资产状态名必须小于20个字符")]
        [Required]
        public string AssetStateName { get; set; }

        /// <summary>
        /// 资产状态备注
        /// </summary>
        public string AssetStateRemarks { get; set; }

        #region 导航属性
        public virtual List<AssetInfo> AssetInfos { get; set; }
        #endregion
    }
}
